#ifndef DBHELPER_H
#define DBHELPER_H

#include <QObject>
#include <QSqlDatabase>
#include <QDebug>
#include <QSqlQuery>
#include <QSqlError>
#include <QMap>
#include <user.h>

class dbhelper
{
private:
    dbhelper();
    dbhelper(const dbhelper& other);

public:
    static dbhelper& get_instance(){
        static dbhelper instance;
        return instance;
    }

public:
    bool init_db();
    QList<User> getAllUsers();

private:
    QSqlDatabase m_db;

};

#endif // DHHELPER_H
